using Boo.Lang;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using UnityEngine;

[Serializable]
public class rate1 : MonoBehaviour
{
	[Serializable]
	[CompilerGenerated]
	internal sealed class _0024rate_0024433 : GenericGenerator<WaitForSeconds>
	{
		internal rate1 _0024self__0024435;

		public _0024rate_0024433(rate1 self_)
		{
			_0024self__0024435 = self_;
		}

		public override IEnumerator<WaitForSeconds> GetEnumerator()
		{
			return new _0024(_0024self__0024435);
		}
	}

	public GUISkin skin;

	public void OnGUI()
	{
		GUI.skin = skin;
		GUI.Box(new Rect(Screen.width - 220, Screen.height - 180, 220f, 180f), "If you like Spin-Tops, would you want to rate it?");
		if (GUI.Button(new Rect(Screen.width - 160, Screen.height - 100, 100f, 30f), "YES"))
		{
			PlayerPrefs.SetInt("Rated", 1);
			StartCoroutine(rate());
		}
		if (GUI.Button(new Rect(Screen.width - 150, Screen.height - 60, 80f, 28f), "no"))
		{
			if (PlayerPrefs.GetInt("Rated") == 2)
			{
				PlayerPrefs.SetInt("Rated", 1);
				enabled = false;
				GetComponent<Collider>().enabled = false;
			}
			else
			{
				PlayerPrefs.SetInt("Rated", 2);
				enabled = false;
				GetComponent<Collider>().enabled = false;
			}
		}
	}

	public IEnumerator rate()
	{
		return new _0024rate_0024433(this).GetEnumerator();
	}

	public void Main()
	{
	}
}
